/**
 * 
 */
package com.lvan.bean;

import java.util.Date;

import org.codehaus.jackson.map.annotate.JsonSerialize;
import org.springframework.format.annotation.DateTimeFormat;

import com.lvan.constant.NotNull;
import com.lvan.constant.Size;
import com.lvan.util.CustomTimeSerializer;
import com.lvan.util.DateUtil;


/**
 * @author lvan.he<br>
 * 2013-6-26<br>
 * @version 1.0.0.0 
 */
public class User extends AdvanceEntity{
	private static final long serialVersionUID = 4297849688717357579L;
	private int userId = -1;
    @NotNull(message="用户名不能为空")
    @Size(Max=50,message="用户名太长")
    private String userName;
    @DateTimeFormat(pattern=DateUtil.DATAFORMAT_ALL)
    private Date lastLoginDate;
    private Integer userStatus;
    private String userPwd;
    private String lastLoginIp;
    private Integer failLoginTimes;
    
    public int getRecid()
	{
		return userId;
	}
	public void setRecid(int recid)
	{
		this.userId = recid;
	}
	public int getUserId() {
        return userId;
    }
    public void setUserId(int userId) {
        this.userId = userId;
    }
    public String getUserName() {
        return userName;
    }
    public void setUserName(String userName) {
        this.userName = userName;
    }
    @JsonSerialize(using = CustomTimeSerializer.class)
    public Date getLastLoginDate() {
        return lastLoginDate;
    }
    public void setLastLoginDate(Date lastLoginDate) {
        this.lastLoginDate = lastLoginDate;
    }
    public Integer getUserStatus() {
        return userStatus;
    }
    public void setUserStatus(Integer userStatus) {
        this.userStatus = userStatus;
    }
    public String getUserPwd() {
        return userPwd;
    }
    public void setUserPwd(String userPwd) {
        this.userPwd = userPwd;
    }
    public String getLastLoginIp() {
        return lastLoginIp;
    }
    public void setLastLoginIp(String lastLoginIp) {
        this.lastLoginIp = lastLoginIp;
    }
    public Integer getFailLoginTimes() {
        return failLoginTimes;
    }
    public void setFailLoginTimes(int failLoginTimes) {
        this.failLoginTimes = failLoginTimes;
    }
    
}
